﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DeviceModule.Services
{
    /// <summary>
    /// 注册表接口：用于管理不同型号设备的解析器
    /// </summary>
    public interface IDeviceParserRegistry
    {
        /// <summary>
        /// 注册解析器
        /// </summary>
        /// <param name="model"></param>
        /// <param name="parser"></param>
        void Register(string model, IDeviceParser parser);

        /// <summary>
        /// 获取解析器
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        IDeviceParser GetParser(string model);              
    }
}
